package eval.host.compare;

import java.util.Collections;
import java.util.List;

import com.google.inject.Singleton;

import eval.host.Host;
@Singleton
public class MaxHostSortLIst implements ISortHostList{

	@Override
	public int compare(Host host1, Host host2) {
		return host1.getCurrentCpuLoad()-host2.getCurrentCpuLoad();
	}

	@Override
	public List<Host> sortHostList(List<Host> hostToSort) {
		Collections.sort(hostToSort,this);
		return hostToSort;
	}

}
